<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>管理页面</title>
		<style>
			@font-face {
				font-family:迷你简剪纸;
				src: url(ttf/迷你简剪纸_爱给网_aigei_com.ttf);
			}
			html,body{
				width: 100%;
				height: 100%;
				padding: 0px;
				margin: 0px;
			}
			#anniu{
				background-color:#303643;
				margin: 0px 5px 5px 5px;
				padding: 10px;
				text-align: center;
				font-weight:bold;
				color: #ffffff;
			}
			#anniu:hover{
				background-color:#F5F5F5;
				margin: 0px 5px 5px 5px;
				padding: 10px;
				text-align: center;
				font-weight:bold;
				color: #000000;
			}
		</style>
	</head>
	<body style="display: flex;">
		<div style="width: 250px;height: 100%;background-color: #fff;margin: 0px 0px 0px 0px;box-shadow: 0px 0px 5px #888888;">
			<a style="text-decoration: none;" href="useryemian.php" target="管理"><p id="anniu" style='margin-top: 5px;'>用户管理</p></a>
			<a style="text-decoration: none;" href="liuyanyemian.php" target="管理"><p id="anniu">留言管理</p></a>
		</div>
		<iframe name="管理" src="panduanyemian.php" style="height: 100%;width: 100%;border: 0px;"></iframe>
	</body>
			
</html>

<?php
	error_reporting(0);//关闭提示
	$s = $_GET['s'];//防止刷新
	$DL = $_POST["neirong"];
	require_once('./config.php');
	$con=login();
	//操作判断
	$jduser = $_COOKIE["jduser"];//获取cookie用户名
	$jdpassword = $_COOKIE["jdpassword"];//获取cookie用户名
	if (!$con)
	{
		die('MYSQL链接失败: ' . mysqli_error());
	}
	else
	{
			$sql="select tequan FROM user WHERE tequan='admin' and 用户名='$jduser' and 密码='$jdpassword'";
			$panduan=mysqli_query($con,$sql);
			$row = mysqli_fetch_array($panduan);
			if (mysqli_num_rows($panduan) == NULL)
			{
				header("Location:feifalaiyuan.html");
			}
	}		
?>